package ex102;

import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        Cylinder cylinder = new Cylinder();

        System.out.print("输入圆柱体底面半径: ");
        cylinder.radius = scanner.nextDouble();

        System.out.print("输入圆柱体高度: ");
        cylinder.height = scanner.nextDouble();

        System.out.printf("体积: %.2f\n", cylinder.getVolume());
    }
}
